﻿//  Copyright (c) 2011 Ray Liang (http://www.dotnetage.com)
//  Licensed MIT: http://www.opensource.org/licenses/mit-license.php

using System;
using System.Collections.Generic;
using System.Linq;
using System.Data.Entity;
using System.Linq.Expressions;
using System.Data;
using DNA.Mvc.Data.Entity;

namespace DNA.Mvc.Publishing.Data.Entity
{
    public class GenericPubEntityRepository<T> : EntityRepositoryBase<PubDB, T>
        where T : class
    {
        public GenericPubEntityRepository()
        {
            context = new PubDB();
            dbSet = this.Context.Set<T>();
            IsOwnContext = true;
        }

        public GenericPubEntityRepository(PubDB db)
        {
            context = db;
            dbSet = this.Context.Set<T>();
            IsOwnContext = false;
        }

    }


}
